package fr.ants.model.ai.pathfinding;

import java.util.Stack;

import fr.ants.model.Grid;
import fr.ants.model.Node;
import fr.ants.model.ai.heuristic.IHeuristic;

/** 
 * <p>PathFinder that can generate a path given two points and a grid. It uses a heuristic method that can be parameterized.</p>
 *
 * @author Vianney DUPOY DE GUITARD
 */
public interface IPathFinder {

	/** 
	 * <p>Find a path given two points and a grid. Relies on an heuristic method that can be changed.</p>
	 * @param grid : the grid to use.
	 * @param x1 : x coordinate of the start point.
	 * @param y1 : y coordinate of the start point.
	 * @param x2 : x coordinate of the end point.
	 * @param y2 : y coordinate of the end point.
	 * @param end
	 * @return
	 */
	public Stack<Node> getPath(Grid grid, int x1, int y1, int x2, int y2);

	/** 
	 * <p>Defines what heuristic method will be used.</p>
	 * @param heuristic <p>the new heuristic method.</p>
	 */
	public void setHeuristic(IHeuristic heuristic);
}